const Comment = require('../../model/comment/Comment')

function search(req,res){

    Comment.find({userName: req.query.search})
      .then((result)=>{
          if(result){
              res.json({
                  code:1,
                  msg: '查询成功',
                  data: result
              })
          }else{
              res.json({
                  code:0,
                  msg: '查询失败'
              })
          }
      })
  
}
module.exports = search